package com.server.db.bean;

import com.sandking.tools.SK_Map;
import java.util.ArrayList;
import com.server.db.imp.LtlxImp;
import com.alibaba.fastjson.JSON;
import java.util.Map;
import com.server.db.imp.YhImp;
import com.sandking.io.SK_ByteBuff;
import com.sandking.tools.SK_Plus;
import java.util.List;
import com.server.db.imp.LmImp;
import com.server.db.imp.LtImp;
import java.util.HashMap;

/**
 * 聊天
 */
public class Lt {

	public static final String TABLE_NAME = "聊天";
	public static final String CLASS_NAME = "Lt"; 
	static final int MAX_GET = Short.MAX_VALUE;
	
	//索引名称
	public static final String  Id_IndexName = "id";
	public static final String  Ltlx_id_IndexName = "ltlx_id";
	public static final String  Lm_id_IndexName = "lm_id";
	public static final String  Jsrid_IndexName = "jsrid";
	public static final String  Fyrid_IndexName = "fyrid";
	
	//对象版本号	
	private int _v = 0;
	public int _nextVer(){
		if(_v > MAX_GET) _v = 0;
		return ++_v;
	}
	
	public int _getVer(){
		return _v;
	}
	
	//是否是源对象
	private boolean _source = false;
	
	public boolean is_source() {
		return _source;
	}

	public void set_source(boolean _source) {
		this._source = _source;
	}
	
	//Cache 中的索引
	private String  id_Unique = null;
	private String  ltlx_id_Index = null;
	private String  lm_id_Index = null;
	private String  jsrid_Index = null;
	private String  fyrid_Index = null;
	public Lt updatePrimaryIndex(){
		return updatePrimaryIndex(this);
	}
	
	public static List<Lt> updatePrimaryIndex(List<Lt> lts){
		for(Lt lt : lts){
			updatePrimaryIndex(lt);	
		}
		return lts;
	}
	
	public static Lt updatePrimaryIndex(Lt lt){
		String field = SK_Plus.b(lt.getId()).e();
		lt.setId_Unique(field);
		
		field = SK_Plus.b(lt.getLtlx_id()).e();
		lt.setLtlx_id_Index(field);
		
		field = SK_Plus.b(lt.getLm_id()).e();
		lt.setLm_id_Index(field);
		
		field = SK_Plus.b(lt.getJsrid()).e();
		lt.setJsrid_Index(field);
		
		field = SK_Plus.b(lt.getFyrid()).e();
		lt.setFyrid_Index(field);
		
		return lt;
	}
	
	
	/**
	 * 需要更新字段集
	 */
	private Map<String, Object> updateColumns;

	/* 可能需要补救的字段 */
	private SK_ByteBuff byteBuff = SK_ByteBuff.allocate();
	
	public SK_ByteBuff getSK_ByteBuff(){
		return this.byteBuff;
	}
	
	/** id */
	private int id;
	
	/** 联盟id */
	private String lmid;
	
	/** 内容 */
	private String nr;
	
	/** 聊天类型_id */
	private int ltlx_id;
	
	/** 联盟_id */
	private int lm_id;
	
	/** 接收人id */
	private int jsrid;
	
	/** 发言人id */
	private int fyrid;
	
	/** 创建时间 */
	private java.util.Date cjsj;
	
	
	public Lt() {
		super();
		this._source = true;
	}
	
	public Lt(int id, String lmid, String nr, int ltlx_id, int lm_id, int jsrid, int fyrid, java.util.Date cjsj) {
		super();
		this.id = id;
		this.lmid = lmid;
		this.nr = nr;
		this.ltlx_id = ltlx_id;
		this.lm_id = lm_id;
		this.jsrid = jsrid;
		this.fyrid = fyrid;
		this.cjsj = cjsj;
		this._source = true;
	}
	
	public Map<String, Object> getUpdateColumns() {
		if(updateColumns == null)
			updateColumns = new HashMap<String, Object>();
		return updateColumns;
	}
	
	public void setUpdateColumns(Map<String, Object> updateColumns) {
		this.updateColumns = updateColumns;
	}
	
	public int getId() {
		return id;
	}
	
	public void setId(int id) {
		changeSetId(id);
		if(!this._source){
			byteBuff.writeInt(1);
			byteBuff.writeInt(id);
		}
	}
	
	private void changeSetId(int id) {
		this.id = id;
		if(!this._source){
			addUpdateColumn("id",id);
		}
	}
	
	public void changeIdWith(int id){
		this.id += id;
		changeSetId(this.id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(2);
			byteBuff.writeInt(id);
		}
	}
	public void changeIdWithMin(int id,int min){
		this.id += id;
		this.id = this.id < min ? min : this.id;
		changeSetId(this.id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(3);
			byteBuff.writeInt(id);
			byteBuff.writeInt(min);
		}	
	}
	public void changeIdWithMax(int id,int max){
		this.id += id;
		this.id = this.id > max ? max : this.id;
		changeSetId(this.id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(4);
			byteBuff.writeInt(id);
			byteBuff.writeInt(max);
		}
	}
	public void changeIdWithMaxMin(int id,int max,int min){
		this.id += id;
		this.id = this.id < min ? min : this.id;
		this.id = this.id > max ? max : this.id;
		changeSetId(this.id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(5);
			byteBuff.writeInt(id);
			byteBuff.writeInt(max);
			byteBuff.writeInt(min);
		}	
	}	
	public String getLmid() {
		return lmid;
	}
	
	public void setLmid(String lmid) {
		changeSetLmid(lmid);
		if(!this._source){
			byteBuff.writeInt(6);
			byteBuff.writeString(lmid);
		}
	}
	
	private void changeSetLmid(String lmid) {
		this.lmid = lmid;
		if(!this._source){
			addUpdateColumn("联盟id",lmid);
		}
	}
	
	public String getNr() {
		return nr;
	}
	
	public void setNr(String nr) {
		changeSetNr(nr);
		if(!this._source){
			byteBuff.writeInt(7);
			byteBuff.writeString(nr);
		}
	}
	
	private void changeSetNr(String nr) {
		this.nr = nr;
		if(!this._source){
			addUpdateColumn("内容",nr);
		}
	}
	
	public int getLtlx_id() {
		return ltlx_id;
	}
	
	public void setLtlx_id(int ltlx_id) {
		changeSetLtlx_id(ltlx_id);
		if(!this._source){
			byteBuff.writeInt(8);
			byteBuff.writeInt(ltlx_id);
		}
	}
	
	private void changeSetLtlx_id(int ltlx_id) {
		this.ltlx_id = ltlx_id;
		if(!this._source){
			addUpdateColumn("聊天类型_id",ltlx_id);
		}
	}
	
	public void changeLtlx_idWith(int ltlx_id){
		this.ltlx_id += ltlx_id;
		changeSetLtlx_id(this.ltlx_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(9);
			byteBuff.writeInt(ltlx_id);
		}
	}
	public void changeLtlx_idWithMin(int ltlx_id,int min){
		this.ltlx_id += ltlx_id;
		this.ltlx_id = this.ltlx_id < min ? min : this.ltlx_id;
		changeSetLtlx_id(this.ltlx_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(10);
			byteBuff.writeInt(ltlx_id);
			byteBuff.writeInt(min);
		}	
	}
	public void changeLtlx_idWithMax(int ltlx_id,int max){
		this.ltlx_id += ltlx_id;
		this.ltlx_id = this.ltlx_id > max ? max : this.ltlx_id;
		changeSetLtlx_id(this.ltlx_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(11);
			byteBuff.writeInt(ltlx_id);
			byteBuff.writeInt(max);
		}
	}
	public void changeLtlx_idWithMaxMin(int ltlx_id,int max,int min){
		this.ltlx_id += ltlx_id;
		this.ltlx_id = this.ltlx_id < min ? min : this.ltlx_id;
		this.ltlx_id = this.ltlx_id > max ? max : this.ltlx_id;
		changeSetLtlx_id(this.ltlx_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(12);
			byteBuff.writeInt(ltlx_id);
			byteBuff.writeInt(max);
			byteBuff.writeInt(min);
		}	
	}	
	public int getLm_id() {
		return lm_id;
	}
	
	public void setLm_id(int lm_id) {
		changeSetLm_id(lm_id);
		if(!this._source){
			byteBuff.writeInt(13);
			byteBuff.writeInt(lm_id);
		}
	}
	
	private void changeSetLm_id(int lm_id) {
		this.lm_id = lm_id;
		if(!this._source){
			addUpdateColumn("联盟_id",lm_id);
		}
	}
	
	public void changeLm_idWith(int lm_id){
		this.lm_id += lm_id;
		changeSetLm_id(this.lm_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(14);
			byteBuff.writeInt(lm_id);
		}
	}
	public void changeLm_idWithMin(int lm_id,int min){
		this.lm_id += lm_id;
		this.lm_id = this.lm_id < min ? min : this.lm_id;
		changeSetLm_id(this.lm_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(15);
			byteBuff.writeInt(lm_id);
			byteBuff.writeInt(min);
		}	
	}
	public void changeLm_idWithMax(int lm_id,int max){
		this.lm_id += lm_id;
		this.lm_id = this.lm_id > max ? max : this.lm_id;
		changeSetLm_id(this.lm_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(16);
			byteBuff.writeInt(lm_id);
			byteBuff.writeInt(max);
		}
	}
	public void changeLm_idWithMaxMin(int lm_id,int max,int min){
		this.lm_id += lm_id;
		this.lm_id = this.lm_id < min ? min : this.lm_id;
		this.lm_id = this.lm_id > max ? max : this.lm_id;
		changeSetLm_id(this.lm_id);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(17);
			byteBuff.writeInt(lm_id);
			byteBuff.writeInt(max);
			byteBuff.writeInt(min);
		}	
	}	
	public int getJsrid() {
		return jsrid;
	}
	
	public void setJsrid(int jsrid) {
		changeSetJsrid(jsrid);
		if(!this._source){
			byteBuff.writeInt(18);
			byteBuff.writeInt(jsrid);
		}
	}
	
	private void changeSetJsrid(int jsrid) {
		this.jsrid = jsrid;
		if(!this._source){
			addUpdateColumn("接收人id",jsrid);
		}
	}
	
	public void changeJsridWith(int jsrid){
		this.jsrid += jsrid;
		changeSetJsrid(this.jsrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(19);
			byteBuff.writeInt(jsrid);
		}
	}
	public void changeJsridWithMin(int jsrid,int min){
		this.jsrid += jsrid;
		this.jsrid = this.jsrid < min ? min : this.jsrid;
		changeSetJsrid(this.jsrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(20);
			byteBuff.writeInt(jsrid);
			byteBuff.writeInt(min);
		}	
	}
	public void changeJsridWithMax(int jsrid,int max){
		this.jsrid += jsrid;
		this.jsrid = this.jsrid > max ? max : this.jsrid;
		changeSetJsrid(this.jsrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(21);
			byteBuff.writeInt(jsrid);
			byteBuff.writeInt(max);
		}
	}
	public void changeJsridWithMaxMin(int jsrid,int max,int min){
		this.jsrid += jsrid;
		this.jsrid = this.jsrid < min ? min : this.jsrid;
		this.jsrid = this.jsrid > max ? max : this.jsrid;
		changeSetJsrid(this.jsrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(22);
			byteBuff.writeInt(jsrid);
			byteBuff.writeInt(max);
			byteBuff.writeInt(min);
		}	
	}	
	public int getFyrid() {
		return fyrid;
	}
	
	public void setFyrid(int fyrid) {
		changeSetFyrid(fyrid);
		if(!this._source){
			byteBuff.writeInt(23);
			byteBuff.writeInt(fyrid);
		}
	}
	
	private void changeSetFyrid(int fyrid) {
		this.fyrid = fyrid;
		if(!this._source){
			addUpdateColumn("发言人id",fyrid);
		}
	}
	
	public void changeFyridWith(int fyrid){
		this.fyrid += fyrid;
		changeSetFyrid(this.fyrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(24);
			byteBuff.writeInt(fyrid);
		}
	}
	public void changeFyridWithMin(int fyrid,int min){
		this.fyrid += fyrid;
		this.fyrid = this.fyrid < min ? min : this.fyrid;
		changeSetFyrid(this.fyrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(25);
			byteBuff.writeInt(fyrid);
			byteBuff.writeInt(min);
		}	
	}
	public void changeFyridWithMax(int fyrid,int max){
		this.fyrid += fyrid;
		this.fyrid = this.fyrid > max ? max : this.fyrid;
		changeSetFyrid(this.fyrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(26);
			byteBuff.writeInt(fyrid);
			byteBuff.writeInt(max);
		}
	}
	public void changeFyridWithMaxMin(int fyrid,int max,int min){
		this.fyrid += fyrid;
		this.fyrid = this.fyrid < min ? min : this.fyrid;
		this.fyrid = this.fyrid > max ? max : this.fyrid;
		changeSetFyrid(this.fyrid);
		//不是源对象才记录变更操作
		if(!this._source){
			byteBuff.writeInt(27);
			byteBuff.writeInt(fyrid);
			byteBuff.writeInt(max);
			byteBuff.writeInt(min);
		}	
	}	
	public java.util.Date getCjsj() {
		return cjsj;
	}
	
	public void setCjsj(java.util.Date cjsj) {
		changeSetCjsj(cjsj);
		if(!this._source){
			byteBuff.writeInt(28);
			byteBuff.writeDate(cjsj);
		}
	}
	
	private void changeSetCjsj(java.util.Date cjsj) {
		this.cjsj = cjsj;
		if(!this._source){
			addUpdateColumn("创建时间",cjsj);
		}
	}
	
	
	//接收人id
	public Yh getYhPkJsrid(){
		return YhImp.getById(jsrid);
	}
	//发言人id
	public Yh getYhPkFyrid(){
		return YhImp.getById(fyrid);
	}
	//聊天类型_id
	public Ltlx getLtlxPkLtlx_id(){
		return LtlxImp.getById(ltlx_id);
	}
	//联盟_id
	public Lm getLmPkLm_id(){
		return LmImp.getById(lm_id);
	}
	public void addUpdateColumn(String key, Object val) {
		Map<String, Object> map = getUpdateColumns();
		if (map == null)
			return;
		map.put(key, val);
	}
	/**
	public void clearUpdateColumn() {
		Map<String, Object> map = getUpdateColumns();
		if (map == null)
			return;
		map.clear();
	}
	*/
	public Lt clone(){
		Lt lt = new Lt();
		lt.setId(this.getId());
		lt.setLmid(this.getLmid());
		lt.setNr(this.getNr());
		lt.setLtlx_id(this.getLtlx_id());
		lt.setLm_id(this.getLm_id());
		lt.setJsrid(this.getJsrid());
		lt.setFyrid(this.getFyrid());
		lt.setCjsj(this.getCjsj());
		lt._v = _v;
		lt._source = false;
		return lt.updatePrimaryIndex(); 
	}
	
	public Map<String, Object> toMap(){
        Map<String, Object> result = new HashMap<String, Object>();
        result.put("id", this.id);
        result.put("lmid", this.lmid);
        result.put("nr", this.nr);
        result.put("ltlx_id", this.ltlx_id);
        result.put("lm_id", this.lm_id);
        result.put("jsrid", this.jsrid);
        result.put("fyrid", this.fyrid);
        result.put("cjsj", this.cjsj);
        return result;
    }
    
    public String toString(){
        return toMap().toString();
    }
    
    public String toJson(){
    	return JSON.toJSONString(toMap());
    }
    
    /**
     * 数据库源字段Map
     */
    public Map<String, Object> toColumnNameMap(){
        Map<String, Object> result = new HashMap<String, Object>();
        result.put("id", this.id);
        result.put("联盟id", this.lmid);
        result.put("内容", this.nr);
        result.put("聊天类型_id", this.ltlx_id);
        result.put("联盟_id", this.lm_id);
        result.put("接收人id", this.jsrid);
        result.put("发言人id", this.fyrid);
        result.put("创建时间", this.cjsj);
        return result;
    }
    
    public String toColumnNameString(){
        return toColumnNameMap().toString();
    }
    
    public byte[] toBytes() throws Exception {
    	SK_ByteBuff byteBuff = SK_ByteBuff.allocate();
	    byteBuff.writeInt(this.id);
	    byteBuff.writeString(this.lmid);
	    byteBuff.writeString(this.nr);
	    byteBuff.writeInt(this.ltlx_id);
	    byteBuff.writeInt(this.lm_id);
	    byteBuff.writeInt(this.jsrid);
	    byteBuff.writeInt(this.fyrid);
	    byteBuff.writeDate(this.cjsj);
	    return byteBuff.toByte();
    }
    
    public byte[] toSKBytes(){
    	SK_ByteBuff byteBuff = SK_ByteBuff.allocate();
    	byteBuff.writeMap(toMap());
	    return byteBuff.toByte();
    }
    
     public static Lt createForBytes(byte[] _byte) throws Exception {
     	SK_ByteBuff byteBuff = SK_ByteBuff.wrap(_byte);
     	Lt lt = new Lt();
	    lt.id = byteBuff.readInt(null);
	    lt.lmid = byteBuff.readString(null);
	    lt.nr = byteBuff.readString(null);
	    lt.ltlx_id = byteBuff.readInt(null);
	    lt.lm_id = byteBuff.readInt(null);
	    lt.jsrid = byteBuff.readInt(null);
	    lt.fyrid = byteBuff.readInt(null);
	    lt.cjsj = byteBuff.readDate(null);
	    return lt.updatePrimaryIndex();
     }
     
     public static Lt createForSKBytes(byte[] _byte){
     		SK_ByteBuff byteBuff = SK_ByteBuff.wrap(_byte);
     		@SuppressWarnings("unchecked")
     		Map<String,Object> map = byteBuff.readMap(null);
	     	Lt lt = Lt.createForMap(map);
		    return lt.updatePrimaryIndex();
     }
    
    /**
     * 根据list创建对象
     */
    public static List<Lt> createForColumnNameList(List<Map<String, Object>> list){
    	List<Lt> lts = new ArrayList<Lt>();
		for (Map<String, Object> map : list) {
			lts.add(createForColumnNameMap(map));
		}
		return lts;
    }
    
    /**
     * 根据map创建对象
     */
    public static Lt createForColumnNameMap(Map<String, Object> map){
    	Lt obj = new Lt();
	    obj.id = SK_Map.getInt("id", map);
	    obj.lmid = SK_Map.getString("联盟id", map);
	    obj.nr = SK_Map.getString("内容", map);
	    obj.ltlx_id = SK_Map.getInt("聊天类型_id", map);
	    obj.lm_id = SK_Map.getInt("联盟_id", map);
	    obj.jsrid = SK_Map.getInt("接收人id", map);
	    obj.fyrid = SK_Map.getInt("发言人id", map);
	    obj.cjsj = SK_Map.getDate("创建时间", map);
        return obj.updatePrimaryIndex();
    }
    
    /**
     * 根据list创建对象
     */
    public static List<Lt> createForList(List<Map<String, Object>> list){
    	List<Lt> lts = new ArrayList<Lt>();
		for (Map<String, Object> map : list) {
			lts.add(createForColumnNameMap(map));
		}
		return lts;
    }
    
    /**
     * 根据map创建对象
     */
    public static Lt createForMap(Map<String, Object> map){
    	Lt obj = new Lt();
	    obj.id = SK_Map.getInt("id", map);
	    obj.lmid = SK_Map.getString("lmid", map);
	    obj.nr = SK_Map.getString("nr", map);
	    obj.ltlx_id = SK_Map.getInt("ltlx_id", map);
	    obj.lm_id = SK_Map.getInt("lm_id", map);
	    obj.jsrid = SK_Map.getInt("jsrid", map);
	    obj.fyrid = SK_Map.getInt("fyrid", map);
	    obj.cjsj = SK_Map.getDate("cjsj", map);
        return obj.updatePrimaryIndex();
    }
    
    public static Lt createForJson(String json){
    	Map<String, Object> map = JSON.parseObject(json);
    	return createForMap(map);
    }
    
    public static List<Lt> createForJson(List<String> jsons){
    	List<Lt> lts = new ArrayList<Lt>();
    	for(String json : jsons){
    		lts.add(createForJson(json));
    	}
    	return lts;
    }
    
    /** 级联删除(延迟入库) */
    public boolean deleteAndSon(){
    	return false;
    }
    
    /** 级联删除(及时入库) */
    public boolean deleteAndSonAndFlush(){
    	return false;
    }
    
    /** 延迟插入数据库 */
    public Lt insert(){
    	return LtImp.insert(this);
    }
    /** 延迟更新数据库 */
    public Lt update(){
    	return LtImp.update(this);
    }
    /** 延迟删除数据库 */
    public boolean delete(){
    	return LtImp.delete(this);
    }
    /** 即时插入数据库 */
    public Lt insertAndFlush(){
    	return LtImp.insertAndFlush(this);
    }
    /** 即时更新数据库 */
    public Lt updateAndFlush(){
    	return LtImp.updateAndFlush(this);
    }
    /** 即时删除数据库 */
    public boolean deleteAndFlush(){
    	return LtImp.deleteAndFlush(this);
    }
    
    
    
    //--------------------------------Cache 中的索引 GET & SET
	public String getId_Unique(){
		return id_Unique;
	}
	
	public void setId_Unique(String id_Unique){
		this.id_Unique = id_Unique;
	}
	
	public String getLtlx_id_Index(){
		return ltlx_id_Index;
	}
	
	public void setLtlx_id_Index(String ltlx_id_Index){
		this.ltlx_id_Index = ltlx_id_Index;
	}
	
	public String getLm_id_Index(){
		return lm_id_Index;
	}
	
	public void setLm_id_Index(String lm_id_Index){
		this.lm_id_Index = lm_id_Index;
	}
	
	public String getJsrid_Index(){
		return jsrid_Index;
	}
	
	public void setJsrid_Index(String jsrid_Index){
		this.jsrid_Index = jsrid_Index;
	}
	
	public String getFyrid_Index(){
		return fyrid_Index;
	}
	
	public void setFyrid_Index(String fyrid_Index){
		this.fyrid_Index = fyrid_Index;
	}
	
	
	
	/** 取得改变的索引 */
	public Map<String,String> getUpdateIndexs(){
		Map<String,String> indexNames = new HashMap<String,String>();
		if(!this.getId_Unique().equals(SK_Plus.b(id).e())){
			indexNames.put(Lt.Id_IndexName,SK_Plus.b(id).e());
			indexNames.put("isUpdtaeUnique","true");
		}
			
		if(!this.getLtlx_id_Index().equals(SK_Plus.b(ltlx_id).e()))
			indexNames.put(Lt.Ltlx_id_IndexName,SK_Plus.b(ltlx_id).e());
			
		if(!this.getLm_id_Index().equals(SK_Plus.b(lm_id).e()))
			indexNames.put(Lt.Lm_id_IndexName,SK_Plus.b(lm_id).e());
			
		if(!this.getJsrid_Index().equals(SK_Plus.b(jsrid).e()))
			indexNames.put(Lt.Jsrid_IndexName,SK_Plus.b(jsrid).e());
			
		if(!this.getFyrid_Index().equals(SK_Plus.b(fyrid).e()))
			indexNames.put(Lt.Fyrid_IndexName,SK_Plus.b(fyrid).e());
			
		return indexNames;
	}
}